import request from '../utils/request'


//显示网站信息
export function getwebsite(){
    return request.get(`/websiteManagement/getWebsite`)
}

//修改网站信息
export function addWebsite(id,data){
    return request.post(`/websiteManagement/website/${id}`,data)
}
//获得关于我们的数据
export function getAboutOur(){
    return request.get(`/WebsiteManagement/aboutour`)
}

//修改关于我们信息
export function addAboutOur(id,data){
    return request.post(`/WebsiteManagement/aboutour/${id}`,data)
}

//上传二维码
export function addQrCode(form){
    return request.post(`/WebsiteManagement/addcode`,form,{"Content-Type":" multipart/form-data"});
}

//获得所有二维码
export function getQrCode(){
    return request.get(`/WebsiteManagement/allcode`)
}

//是否启用禁用二维码
export function IsEnableCode(id,data){
    return request.post(`/WebsiteManagement/isenablecode/${id}`,data)
}

//修改二维码
export function editQrCode(id,data){
    return request.put(`/WebsiteManagement/editcode/${id}`,data)
}

//删除二维码
export function deleteQrCode(id){
    return request.post(`/WebsiteManagement/deletecode/${id}`)
}

//添加轮播图片
export function addCarousel(form){
    return request.post(`/carouselpictures`,form,{"Content-Type":" multipart/form-data"})
}

//获取所有的轮播图
export function getAllPicture(){
    return request.get(`/carouselpictures/cps`)
}

//是否启用禁用二维码
export function IsEnableCarPicture(id,data){
    return request.post(`/carouselpictures/isenablepic/${id}`,data)
}

//删除轮播图
export function deleteCarpicture(id){
    return request.post(`/carouselpictures/deletepic/${id}`)
}


//修改轮播图
export function editCarPicture(id,data){
    return request.put(`/carouselpictures/editcar/${id}`,data)
}